package cn.edu.stu.mapper;

import cn.edu.stu.bean.MicUser;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface MicUserMapper {
    int deleteByPrimaryKey(Long userId);

    int insert(MicUser record);

    MicUser selectByPrimaryKey(Long userId);

    List<MicUser> selectAll();

    int updateByPrimaryKey(MicUser record);

    @Select("select * from mic_user where user_act = #{userAct} and user_psw = #{userPsw}")
    MicUser selectByUserNameAndUserPswEquals(MicUser user);

    @Select("select * from mic_user order by user_id")
    List<MicUser> selectUserPage();
}